#include <iostream>
#include <vector>
#include <sstream>
#include <algorithm>

bool placeTree(std::vector<int> &ns, int tn, int interv)
{
    int pos = ns[0];
    int cnt = 1;
    for (int i = 1; i < ns.size(); i++)
    {
        if (ns[i] - pos >= interv)
        {
            cnt++;
            pos = ns[i];
        }
        if (tn == cnt)
        {
            break;
        }
    }

    return tn == cnt;
}

int main()
{
    int N;
    std::cin >> N;
    std::cin.ignore();

    std::string s;
    std::getline(std::cin, s);
    std::istringstream iss(s);
    std::vector<int> ns;
    int n;
    while (iss >> n)
    {
        ns.push_back(n);
    }

    int tn;
    std::cin >> tn;

    std::sort(ns.begin(), ns.end(), std::less<int>());

    int left = ns.front();
    int right = ns.back() - ns.front();
    int res = 0;

    while (left <= right)
    {
        int mid = (left + right) / 2;
        if (placeTree(ns, tn, mid))
        {
            // std::cout << mid << std::endl;
            res = mid;
            left = mid + 1;
        }
        else
        {
            right = mid - 1;
        }
    }
    std::cout << res << std::endl;

    return 0;
}